<include file="Public/ADMIN/HTML/Admin_header/admin_first_head.html" />
<title>新闻列表{$Think.const.TITLE}</title>
<include file="Public/ADMIN/HTML/Admin_header/admin_css_and_js.html" />
<include file="Public/ADMIN/HTML/Admin_header/admin_title.html" />
<include file="Public/ADMIN/HTML/Admin_header/admin_middle_list.html" />
<include file="Public/ADMIN/HTML/Left_list/news_left_list.html" />
<!-- DataTables Example -->
<script>
	function delNews(nid){
		address = "{$Think.const.DOMAIN_NAME}Admin/News/deleteNews/nid/"+nid; // 设置$.get调用路径
		var delTr = document.getElementById(nid);                             // 获取动态的表格ID
		$.get(address,function(str){
			if(str==0){
				ZENG.msgbox.show("删除成功！", 4, 2000);
				delTr.parentNode.removeChild(delTr);                          // 删除该行
			}else{
				ZENG.msgbox.show("删除失败！", 5, 2000);
			}
		});
	}
</script>
<div class="row" style="height: 80%">
	<div class="col-lg-10" style="float: right">
		<div class="widget-container fluid-height clearfix">
			<div class="heading">
				<i class="icon-table"></i>新闻列表
			</div>
			<div class="widget-content padded clearfix">
				<table class="table table-bordered table-striped dataTable"
					id="datatable-editable">
					<thead>
						<th style="width: 8%; text-align: center">编号</th>
						<th style="width: 20%; text-align: center">标题</th>
						<th style="width: 35%; text-align: center">摘要</th>
						<th style="width: 15%; text-align: center">发布时间</th>
						<th style="width: 12%; text-align: center;">发布人</th>
						<th style="width: 10%; text-align: center;">操作</th>
					</thead>
					<tbody>
						<assign name="number" value="1" />
						<volist name="info" id="vo">
						<tr id="{$vo.nid}">
							<td style="text-align: center;">{$number++}</td>
							<td style="text-align: center;"><a
								href="{$Think.const.DOMAIN_NAME}Home/News/details/nid/{$vo.nid}"
								target="_blank" title="查看详细">{$vo.title}</a></td>
							<td style="text-align: center;">{$vo.summary}</td>
							<td style="text-align: center;">{$vo.dtime}</td>
							<td style="text-align: center;">{$vo.issuer}</td>
							<td style="text-align: center; width: 9%">
								<div class="action-buttons" style="margin-left: -14%">
									<a class="table-actions" title="修改"
										href="{$Think.const.DOMAIN_NAME}Admin/News/modifyNews/nid/{$vo.nid}"><i
										class="icon-pencil"></i></a> <a class="table-actions" title="删除"
										onclick="if(confirm('确定要删除吗?')==false){ return false; }else{ javascript:delNews({$vo.nid}); }"><i
										class="icon-trash"></i></a>
								</div>
							</td>
						</tr>
						</volist>
					</tbody>
				</table>
			</div>
		</div>
	</div>
</div>
<!-- end DataTables Example -->
</div>
</div>
</body>
</html>